package ai.people.netmon.framework.exception.enums;

/**
 * 账号异常枚举
 *
 * @author yuanqinglong
 * @date 2022/2/15 17:16
 */
public enum AccountExceptionEnum implements ExceptionEnum{
    ACCOUNT_DOES_NOT_EXIST(false, 210000, "账号不存在！"),
    ACCOUNT_EXIST(false, 210001, "账号已存在！"),
    ACCOUNT_IS_NOT_ASSIGNED_A_ROLE(false, 210002, "账号未分配角色！"),
    ACCOUNT_IS_NOT_ASSIGNED_A_MENU(false, 210003, "账号未分配菜单！"),
    FAILED_TO_GET_ACCOUNT_INFORMATION(false, 210004, "未获取到账号信息！");
    //ACCOUNT_DOES_NOT_EXIST(false, 210000, "账号ID、账号名称、账号链接不可同时");


    /**
     * 状态
     */
    final boolean status;
    /**
     * 代码
     */
    final int code;
    /**
     * 消息
     */
    final String message;

    AccountExceptionEnum(boolean status, int code, String message) {
        this.status = status;
        this.code = code;
        this.message = message;
    }

    @Override
    public Integer getCode() {
        return code;
    }

    @Override
    public String getMessage() {
        return message;
    }

    @Override
    public boolean getStatus() {
        return status;
    }
}
